package io;

import java.io.File;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: hp
 * Date: 2024-08-15
 * Time: 16:34
 */
public class Demo2 {
    public static void main(String[] args) {
        File file = new File("./text.txt");
        boolean tf1 = file.delete();//根据File对象删除该文件，成功返回true。
        System.out.println(tf1);
        boolean tf2 = file.delete();
        System.out.println(tf2);
    }
}
